package cn.ym.org.domain;


import cn.ym.basic.domain.BaseDomain;
import cn.ym.system.domain.Role;
import lombok.*;


import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotEmpty;
import java.io.Serializable;

/**
 * 实体类：员工
 */
@Data//get、set
@AllArgsConstructor//全参构造
@NoArgsConstructor//无参构造
@ToString//打印
public class Employee  extends BaseDomain {

    //员工名称
    @NotBlank(message = "员工名称不能为空")
    private String username;
    //员工电话
    @NotBlank(message = "员工电话不能为空")
    private String phone;
    //员工邮箱
    @NotBlank(message = "员工邮箱不能为空")
    private String email;
    //员工盐值
    private String salt;
    //员工密码
    private String password;
    //员工年龄
    private Integer age;
    //员工状态：1启用 0禁用
    private Integer state = 1;
    //员工所属部门ID
    private Long departmentId;
    private Department department;

    //登录信息ID
    private Long logininfoId;

    //店铺ID：为空=平台系统管理员，不为空=店铺管理员
    private Long shopId;
    private Shop shop;

    //所属角色
    private Long roleId;
    private Role role;

}